package com.yun.zf.system.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yun.zf.common.app.domain.SysCouponReceive;
import com.yun.zf.common.app.dto.center.MyCouponListDto;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 优惠券领取记录表 服务类
 * </p>
 *
 * @author cj
 * @since 2021-05-31
 */
public interface SysCouponReceiveService extends IService<SysCouponReceive> {

    /**
     * 发放新人优惠券
     * @param couponReceive
     * @return
     */
    public int receiveCoupon(SysCouponReceive couponReceive);

    public Map<Integer, List<MyCouponListDto>> getCouponList(Long userId);

    /**
     * 领取优惠券
     * @param couponId
     * @param userId
     * @return
     */
    int receiveCoupon(String couponId,String userId);
}
